import { request } from "@/http/axios"
export function projectAll() {
  return request({
    url: '/projectType/all',
    method: "get"
  })
}

export function selectProjectTitle(title) {
  const url = `project/title?title=${encodeURIComponent(title)}`;
  return request({
    url: url,
    method: 'get',
  })
}
export function delectUser(id) {
  const url = `user/delectUser?id=${encodeURIComponent(id)}`;
  return request({
    url: url,
    method: 'get',
  })
}
export function changeInformation(form) {
  return request({
    url: '/user/changeInformation',
    method: "post",
    data: form
  })
}

//获取用户信息通知
export function getUserMessage(id) {
  return request({
    url: '/authentication/notification',
    method: "get",
    params: {
      userId: id
    }
  })
}
// 修改用户信息通知状态
export function updateUserMessageStatus(data) {
  return request({
    url: '/authentication/notification',
    method: "put",
    data: data
  })
}

//用户认证
export function userAuthentication(data) {
  return request({
    url: '/authentication',
    method: "post",
    data: data
  })
}

//获取用户认证信息
export function getUserAuthenticationInfo(id) {
  return request({
    url: '/authentication/info?userId='+id,
    method: "get",
    })
}

// 验证验证码
export function verificationCode(data) {
  return request({
    url: 'user/verificationCode',
    method: "post",
    data: data
  })
}
// 重置密码
export function resetPassword(data) {
  return request({
    url: 'user/exitPassword',
    method: "post",
    data: data
  })
}
// 修改手机号
export function changePhone(data) {
  return request({
    url: 'user/bindPhone',
    method: "post",
    data: data
  })
}
// 修改邮箱
export function changeEmail(data) {
  return request({
    url: 'user/changeAddress',
    method: "post",
    data: data
  })
}














